<?php $this->_extends('_layouts/cib_layout'); ?>

<?php $this->_block('metainfo'); ?>
    <title>首页 —— 上海外国语大学国际工商管理学院</title>
    <meta name="Description" content="上海外国语大学国际工商管理学院,SISUCIB,首页" />
    <meta name="Keywords"    content="上海外国语大学国际工商管理学院,SISUCIB,首页" />
    <link rel="stylesheet" type="text/css" href="profiles/<?=Q::ini('appini/skin');?>/cib-home.css" />
<?php $this->_endblock('metainfo'); ?>

<?php $this->_block('container'); ?>
<div id="home-precontainer" class="tz980">
    <h2>欢迎访问 上海外国语大学 国际工商管理学院</h2>
    <div id="hwrapper">
        <div class="column-a">
            <ul>
                <li><b>学院新闻</b><a href="<?=url('newsnotice/index' ,array('ctgry_id'=>4));?>">更多 >></a></li>
                <?php foreach(News::find('category_id in (?)', NewsCategory::getSelfArrayId(array(4,7,8)))   ->all()->order(Q::ini('appini/sort'))
            ->limit(0, 3)->query() as $n) { ?>
                <li>
                    <a title="<?=mb_substr(strip_tags($n->body), 0, Q::ini('appini/alink_title'), 'utf-8');?>" href="<?=url('newsnotice/index' ,array('news_id'=>$n->news_id, 'title'=>mb_substr($n->title, 0, Q::ini('appini/ahref_title'), 'utf-8')));?>">
                    <?=mb_substr($n->title, 0 ,24, 'utf-8');?>
                    </a>
                </li>
                <?php } ?>
                <li>&nbsp;</li>
                <li><b>学院通知</b><a href="<?=url('newsnotice/index', array('ctgry_id'=>23));?>">更多 >></a></li>
                <?php foreach(News::find(NewsCategory::genCondition(23))->all()->order(Q::ini('appini/sort'))
            ->limit(0, 3)->query() as $n) { ?>
                <li>
                    <a title="<?=mb_substr(strip_tags($n->body), 0, Q::ini('appini/alink_title'), 'utf-8');?>" href="<?=url('newsnotice/index',array('news_id'=>$n->news_id, 'title'=>mb_substr($n->title, 0, Q::ini('appini/ahref_title'), 'utf-8')));?>">
                    <?=mb_substr($n->title, 0, 24, 'utf-8');?>
                    </a>
                </li>
                <?php } ?>
            </ul>
        </div><!-- /.column-a -->

        <div class="column-b">
            <div id="picturenews">
            <?php
                /**
                 * 可控的链接新闻id
                 */
                $pictureNewsId   = AppStore::find('hkey = ?', 'home_pic_news_id')->query()->hvalue;
                /**
                 * 可控的显示字符，非文章标题
                 */
                $pictureNewsText = AppStore::find('hkey = ?', 'home_pic_news_text')->query()->hvalue;
                # 更新值时注意，pictureNewsId不能输入非数字。由于只能高权限角色操作，这里跳过检验，默认hvalue列为输入数字
                /**
                 * 图片新闻
                 */
                $pictureNews = News::find('news_id = ?', $pictureNewsId)->query();
            ?>
                <a title="<?=mb_substr(strip_tags($pictureNews->body), 0, Q::ini('appini/alink_title'), 'utf-8');?>" href="<?=url('newsnotice/index' ,array('news_id'=>$pictureNewsId, 'title'=>mb_substr($pictureNews->title, 0, Q::ini('appini/ahref_title'), 'utf-8')));?>">
                    <img src="misc/home-index.jpg" alt="<?=$pictureNewsText;?>"/>
                    <span><?=$pictureNewsText;?></span>
                </a>
            </div><!-- /图片新闻 -->
        </div><!-- /.column-b -->

        <div class="column-c">
            <ul>
                <li>&nbsp;</li>
                <li><b><a class="highlight" style="text-decoration:underline;" href="#">上海外国语大学试办MBA教育复审材料 >></a></b></li>
                <li>&nbsp;</li>
                <li><b>专业介绍</b>&nbsp;
                    <a href="<?=url('education/index', array('ctgry_id'=>26, 'news_id'=>176, 'title'=>'本科招生FAQ'));?>" style="text-decoration:underline;">本科招生FAQ >></a>&nbsp;
                    <a href="<?=url('education/index', array('ctgry_id'=>26, 'news_id'=>180, 'title'=>'研究生招生FAQ'));?>" style="text-decoration:underline;">研究生招生FAQ >></a>
                </li>
                <li><a href="<?=url('education/index', array('ctgry_id'=>26, 'news_id'=>177, 'title'=>'工商管理专业-09版'));?>">工商管理(英语)专业(本科四年制)-2009版</a></li>
                <li><a href="<?=url('education/index', array('ctgry_id'=>26, 'news_id'=>178, 'title'=>'信息管理与信息系统专业-09版'));?>">信息管理与信息系统(英语)专业(本科四年制)-2009版</a></li>
                <li><a href="<?=url('education/index', array('ctgry_id'=>26, 'news_id'=>179, 'title'=>'公共关系专业-09版'));?>">公共关系(英语)专业(本科四年制)-2009版</a></li>
                <li>&nbsp;</li>
                <li><b>热门标签</b>
                    <?php foreach(Tag::find('isonhomepage = 1 AND category = ?', '新闻通知')->all()->query() as $tag) { ?>
                    <a href="<?=url('newsnotice/index',array('tag'=>$tag->tag));?>" class="highlight"><?=$tag->tag;?></a>
                    <?php } ?>
                </li>
            </ul>
        </div><!-- /.column-c -->
    </div>
</div><!-- /home-precontainer -->
<?php $this->_endblock('container'); ?>